<include file="Public:header"/>
<form action="" method="post">
<div class="form_data">
	<div class="mod_name">
		<span class="name">
			<eq name="info.id" value="">添加<else/>修改</eq>版本
		</span>
	</div>

	<div class="mod_data">
		<div class="name">类型</div>
		<div class="input_data">
			<php>

				$client_type = $info['client_type']?$info['client_type']:$_GET['client_type'];
				$client_type = $client_type?$client_type:'android';

				$user_type = $info['user_type']?$info['user_type']:$_GET['user_type'];
				$user_type = $user_type?$user_type:'teacher';
			</php>
			<eq name="client_type" value="android">
				Android版<eq name="user_type" value="teacher">老师端<else/>学生端</eq>
			</eq>
			<eq name="client_type" value="ios">
				iOS<eq name="user_type" value="teacher">老师端<else/>学生端</eq>
			</eq>
		</div>
	</div>

	<div class="mod_data">
		<div class="name">版本名称</div>
		<div class="input_data">
			<eq name="info.id" value="">
			<input type="text" name="version_name" value="{$info['version_name']}" datatype="*">
			如1.0.0
			<else/>
			{$info['version_name']}
			</eq>
		</div>
	</div>

	<div class="mod_data">
		<div class="name">内部版本号</div>
		<div class="input_data">
			<eq name="info.id" value="">
			<input type="text" name="version_code" value="{$info['version_code']}" datatype="number">
			用于版本更新判断
			<else/>
			{$info['version_code']}
			</eq>
		</div>
	</div>

	<div class="mod_data">
		<div class="name">下载地址</div>
		<div class="input_data">
			<input type="text" name="download_url" value="{$info['download_url']}" datatype="url" ignore="ignore">
		</div>
	</div>

	<!-- 上传图片 -->
	<php>
		$upload_field = 'file_id';
		$upload_type  = 'app';
		$upload_name  = 'APP文件';
	</php>
	<include file="File:common_upload"/>

	<div class="mod_data">
		<div class="name">更新日期</div>
		<div class="input_data">
			<eq name="info.id" value="">
			<input type="text" name="update_date" value="{$info['update_date']|default=date('Y-m-d')}" datatype="*" onclick="WdatePicker()">
			<else/>
			{$info['update_date']}
			</eq>
		</div>
	</div>

	<div class="mod_data">
		<div class="name">更新内容</div>
		<div class="input_data">
			<textarea name="content" style="width:300px;height:150px" datatype="*">{$info['content']}</textarea>
		</div>
	</div>

	<div class="mod_submit">
		<input type="hidden" name="create_user_id" value="{$_user_id}">
		<input type="hidden" name="client_type" value="{$client_type}">
		<input type="hidden" name="user_type" value="{$user_type}">
		<input type="hidden" name="id" value="{$info['id']}">
		<input type="hidden" name="customer_id" value="{$customer_id}">
		<input type="submit" value="保存" class="btn1">
		<input type="reset" value="重置" class="btn2">
	</div>
</div>
</form>
<include file="Public:footer"/>